package org.jaaksi.svcmanager;

import android.content.ContentProvider;
import android.content.ContentValues;
import android.database.Cursor;
import android.net.Uri;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;

/**
 * server端注册provider
 * <provider
 *    android:exported="true"
 *    android:authorities="{packageName}.svcmanager"
 *    android:name="org.jaaksi.svcmanager.BinderProvider"/>
 */
public class BinderProvider extends ContentProvider {
  public static final String AUTHORITY_SUFFIX = ".svcmanager";

  public static final String PATH_SERVER_CHANNEL = "severchannel";
  public static final String TAG = BinderProvider.class.getSimpleName();

  @Override
  public boolean onCreate() {
    return true;
  }

  @Nullable
  @Override
  public Cursor query(@NonNull Uri uri, @Nullable String[] projection, @Nullable String selection,
    @Nullable
      String[] selectionArgs, @Nullable String sortOrder) {
    return ServiceManager.sCursor;
  }

  @Nullable
  @Override
  public String getType(@NonNull Uri uri) {
    return null;
  }

  @Nullable
  @Override
  public Uri insert(@NonNull Uri uri, @Nullable ContentValues values) {

    return null;
  }

  @Override
  public int delete(@NonNull Uri uri, @Nullable String selection,
    @Nullable String[] selectionArgs) {
    return 0;
  }

  @Override
  public int update(@NonNull Uri uri, @Nullable ContentValues values, @Nullable String selection,
    @Nullable
      String[] selectionArgs) {

    return 0;
  }
}